package com.mew.common.rest.mail;

import com.zebra.common.ZebraBaseMessage;
import io.netty.buffer.ByteBuf;
import lombok.*;

import java.util.List;

/**
 * @author dylin
 * @create 2021/4/1
 */
@Data
@ToString
@AllArgsConstructor
@NoArgsConstructor
@Builder
public class MailResponseMessage extends ZebraBaseMessage<MailResponseMessage> {
    private List<MailBO> mailList;
    @Override
    public void write(ByteBuf b) {

        writeInt(b,mailList.size());
        for (MailBO mailBO : mailList) {
            mailBO.write(b);
        }
    }

    @Override
    public MailResponseMessage read(ByteBuf byteBuf) {
        return null;
    }
}
